<admintpl file="header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
	        <li class="active"><a href="#A" data-toggle="tab">{:L('GENERAL_SETTING')}</a></li>
	        <li><a href="#B" data-toggle="tab">{:L('SEO_SETTING')}</a></li>
	        <li><a href="#C" data-toggle="tab">{:L('TEMPLATE_SETTING')}</a></li>
	    </ul>
		<form class="form-horizontal js-ajax-form" action="{:U('AdminTerm/add_post')}" method="post">
			<div class="tabbable">
		        <div class="tab-content">
		          <div class="tab-pane active" id="A">
						<fieldset>
							<div class="control-group">
								<label class="control-label">{:L('PARENT')}</label>
								<div class="controls">
									<select name="parent">
										<option value="0">{:L('ROOT')}</option>
										{$terms_tree}
									</select>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('NAME')}</label>
								<div class="controls">
									<input type="text" name="name" value=""><span class="form-required">*</span>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('CATEGORY_DESCRIPTION')}</label>
								<div class="controls">
									<textarea name="description" rows="5" cols="57"></textarea>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('CATEGORY_TYPE')}</label>
								<div class="controls">
									<select name="taxonomy">
										<foreach name="taxonomys" item="vo">
								        	<option value="{$key}">{$vo}</option>
										</foreach>
									</select>
								</div>
							</div>
						</fieldset>
		          </div>
		          <div class="tab-pane" id="B">
						<fieldset>
							<div class="control-group">
								<label class="control-label">{:L('SEO_TITLE')}</label>
								<div class="controls">
									<input type="text" name="seo_title" value="">
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('SEO_KEYWORDS')}</label>
								<div class="controls">
									<input type="text" name="seo_keywords" value="">
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('SEO_DESCRIPTION')}</label>
								<div class="controls">
									<textarea name="seo_description" rows="5" cols="57"></textarea>
								</div>
							</div>
						</fieldset>
		          </div>
		          <div class="tab-pane" id="C">
						<php>$tpl_list=sp_admin_get_tpl_file_list();</php>
						<fieldset>
							<div class="control-group">
								<label class="control-label">{:L('LIST_TEMPLATE')}</label>
								<div class="controls">
									<php>
										$list_tpls=$tpl_list;
										unset($list_tpls['list']);
									</php>
				              		<select  name="list_tpl">
				              			<option value="list">list{:C("TMPL_TEMPLATE_SUFFIX")}</option>
				              			<foreach name="list_tpls" item="vo">
				              				<option value="{$vo}">{$vo}{:C("TMPL_TEMPLATE_SUFFIX")}</option>
				              			</foreach>
				              		</select>
								</div>
							</div>
							<div class="control-group">
								<label class="control-label">{:L('ARTICLE_TEMPLATE')}</label>
								<div class="controls">
									<php>
										$article_tpls=$tpl_list;
										unset($article_tpls['article']);
									</php>
				              		<select  name="one_tpl">
				              			<option value="article">article{:C("TMPL_TEMPLATE_SUFFIX")}</option>
				              			<foreach name="article_tpls" item="vo">
				              				<option value="{$vo}">{$vo}{:C("TMPL_TEMPLATE_SUFFIX")}</option>
				              			</foreach>
				              		</select>
								</div>
							</div>
						</fieldset>
		          </div>
		        </div>
		    </div>
		    <div class="form-actions">
		     	<button class="btn btn-primary js-ajax-submit"type="submit">{:L('ADD')}</button>
		      	<a class="btn" href="{:U('AdminTerm/index')}">{:L('BACK')}</a>
		    </div>
		</form>
	</div>
	<script type="text/javascript" src="__PUBLIC__/js/common.js"></script>
</body>
</html>